package com.hl.mapper;

import com.hl.domain.Article;
import org.apache.ibatis.annotations.Param;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

/**
* @author Administrator
* @description 针对表【article(文章表，存储所有文章信息)】的数据库操作Mapper
* @createDate 2024-09-05 20:27:23
* @Entity com.hl.domain.Article
*/
public interface ArticleMapper {

    //删除
    int deleteByPrimaryKey(Long id);


    int insert(Article record);

    //新增
    int insertSelective(Article record);

    Article selectByPrimaryKey(Long id);

    //修改
    int updateByPrimaryKeySelective(Article record);

    int updateByPrimaryKey(Article record);

    //查询所有
    List<Article> findAllArticle(Integer pageNum,Integer pageSize);

    //根据条件查询
    List<Article> findAllByLike(@Param("articlename") String articlename, @Param("typeName") String typeName, @Param("startTime") Date startTime, @Param("endTime")Date endTime);
}
